#include <iostream>

/* run this program using the console pauser or add your own getch, system("pause") or input loop */

int main(int argc, char** argv) {
	int i,j,n,s,sum,a;
	s=1;
	sum=0;
	scanf("%d",&n);
    a=1;
    
	for( i=1;i<=n;i++){
		for(int j=1;j<=i;i--){
		s=j*i;
		a=a*s; 
		sum=sum+a;
		}
	}
	printf("%d",sum);
	return 0;
}
